package com.knowvoyage.knowvoyageserver.service;

import com.github.pagehelper.PageInfo;
import com.knowvoyage.knowvoyageserver.pojo.dto.ErrorRecordDTO;
import com.knowvoyage.knowvoyageserver.pojo.entity.ErrorBook;
import com.knowvoyage.knowvoyageserver.pojo.entity.ErrorRecord;
import com.knowvoyage.knowvoyageserver.pojo.vo.ErrorRecordVO;
import com.knowvoyage.knowvoyageserver.pojo.vo.Result;

import java.util.List;

public interface ErrorBookService {
    Result<Boolean> insert(ErrorBook errorBook);
    Result<List<ErrorBook>> selectByUserId(Long userId);
    PageInfo<ErrorBook> selectAllByUser(Long userId, int pageNum, int pageSize);
    PageInfo<ErrorRecordVO> selectAllRecordByBookId(Long bookId, int pageNum, int pageSize);
    PageInfo<ErrorRecordVO> selectEbbingRecordByBookId(Long bookId, int pageNum, int pageSize);
    Result<Boolean> delete(Long bookId);
    Result<Boolean> update(ErrorBook errorBook);
    Result<List<ErrorBook>> selectAll();
    Result<Boolean> insertRecord(ErrorRecord errorRecord);

    Result<Boolean> deleteRecord(Long recordId);

    Result<Boolean> insertRecordsBatch(List<ErrorRecord> records, Long userId);

    Result<Boolean> deleteRecordsBatch(List<Long> recordIds, Long userId);

}
